package edu.faytechcc.csc.gui.search.details;

import javax.swing.Box;
import javax.swing.JLabel;
import javax.swing.JPanel;

/**
 * Creates a panel used to display the English Title, Japanese Title, Number of
 * Episodes or Volumes, and the Artist or Producer.
 *
 * @author Stephanie Mckenzie and Jasmin Pastari
 */
public class TitlePanel extends JPanel
{

    private JLabel englishTitleLabel;
    private JLabel japaneseTitleLabel;
    private JLabel numberOrVolumesLabel;
    private JLabel artistLabel;

    /**
     * Constructor for the TitlePanel class that accepts four Strings, using
     * them to create the labels.
     *
     * @param engTitle
     * @param japTitle
     * @param num
     * @param artist
     */
    public TitlePanel(String engTitle, String japTitle, String num, String artist)
    {
        englishTitleLabel = new JLabel("English Title: " + engTitle);
        japaneseTitleLabel = new JLabel("Japanese Title: " + japTitle);
        numberOrVolumesLabel = new JLabel("Number of Episodes/Volumes: " + num);
        artistLabel = new JLabel("Artist/Producer: " + artist);

        this.add(englishTitleLabel);
        this.add(Box.createHorizontalGlue());
        this.add(japaneseTitleLabel);
        this.add(Box.createHorizontalGlue());
        this.add(numberOrVolumesLabel);
        this.add(Box.createHorizontalGlue());
        this.add(artistLabel);
    }
}
